package com.nq.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.nq.dao.StLimitUpStockMapper;
import com.nq.pojo.StLimitUpStock;
import com.nq.service.IStLimitUpStockService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
public class StLimitUpStockServiceImpl implements IStLimitUpStockService {

    @Resource
    private StLimitUpStockMapper stLimitUpStockMapper;

    @Override
    public StLimitUpStock getLimitUpByCodeAndMarket(String market, String code) {
        QueryWrapper<StLimitUpStock> queryWrapper = new QueryWrapper<>();
        queryWrapper.eq("market", market);
        queryWrapper.eq("stock_code", code);
        StLimitUpStock stLimitUpStock = stLimitUpStockMapper.selectOne(queryWrapper);
        return stLimitUpStock;
    }
}
